#pragma once

#include <vector>

#include "../Math/Matrix2.h"

using namespace std;

class CNN
{
public:
	struct ConvLayerParam
	{
		int ConvWindowSize;
		int FeatureCount;
	};
	
public:
	CNN() = delete;

	CNN(int ViewSize, ConvLayerParam ConvLayers[]);

public:
	Matrix2 Execute(Matrix2 & Input);

protected:
	struct ConvProcessor
	{
		ConvProcessor(int nConvWindowSize);

		void Convolution(shared_ptr<Matrix2> & input, shared_ptr<Matrix2> & output);

		Matrix2 ConvW;
		double  ConvB;

		double  SubSimpleW;
		double  SubSimpleB;

	};

protected:
	static double Sigmoid(double value);

protected:
	vector< vector<ConvProcessor> > m_ConvLayers;

};